﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using PaceR.Core.Interfaces.Conditionals;

namespace PaceR.Core.Interfaces.Validation
{
    public interface IValidatableField<T>
    {
        string FieldIdentifer { get; set; }
        T FieldValue { get; set; }
        bool IsRequired { get; set; }
        IValidationBounds<T> Bounds { get; set; }
        string ValidPattern { get; set; }
        string InvalidPattern { get; set; }

        IEnumerable<IConditionRule> BuildRules();
        IValidatableField<T> SetRequired();
        IValidatableField<T> SetBounds(IValidationBounds<T> bounds);
        IValidatableField<T> SetValidPattern(string pattern);
        IValidatableField<T> SetInvalidPattern(string pattern);
    }
}
